Skip to content

Odp/gardener revendor - #316

Open
christianhuening wants to merge 28 commits into
23technologies:mainfrom
opendefensecloud:odp/gardener-revendor
Open

Odp/gardener revendor#316
christianhuening wants to merge 28 commits into
23technologies:mainfrom
opendefensecloud:odp/gardener-revendor

Conversation

@christianhuening

Copy link
Copy Markdown

Disclaimer: These changes have been heavily co-authored with Claude Code

What this PR does / why we need it:
Revendors gardener-extension-provider-hcloud from the currently pinned Gardener v1.106.1 up to v1.144.1, bringing the extension back in line with the current Gardener extensions contract and unblocking newer shoots. In detail:

  • Gardener revendor v1.106.1 → v1.144.1 (in steps: 1.107 → 1.113 → 1.119 → 1.122.3 → 1.144.1), with the corresponding bumps to sigs.k8s.io/controller-runtime 0.20 → 0.23, k8s.io/* → 0.35.5, machine-controller-manager → v0.62.0, and etcd-druid → v0.27.0.
  • Kubernetes support extended to v1.31 – v1.35.
  • MachineDeployment update strategy now honors the worker pool's update strategy, adding in-place updates (RollingUpdate, InPlaceUpdate auto, and ManualInPlace) alongside per-zone MaxSurge/MaxUnavailable distribution, matching the newer MCM API.
  • VPA migrated to autoscaling.k8s.io/v1 (from the deprecated beta API) across the extension, MCM, and CSI controller charts.
  • containerd pinned to 1.7.x to avoid a known regression in containerd 2.2.
  • RBAC: grant patch on coordination.k8s.io leases so the extension can update its own heartbeat lease.
  • Regenerated mocks and generated code (update-codegen.sh), and updated the example controller-registration.yaml.

Which issue(s) this PR fixes:
Fixes #310

Special notes for your reviewer:

  • This is a large diff because it spans 38 minor Gardener versions, but the bulk is go.mod/go.sum and generated/mocked code — the hand-written changes are concentrated in pkg/controller/worker/machines.go, pkg/controller/controlplane/valuesprovider.go, pkg/webhook/controlplane/ensurer.go, the charts, and the RBAC template.
  • Take a closer lookat the in-place vs. rolling-update branching in machines.go and the VPA v1 cutover.

Release note:

`gardener-extension-provider-hcloud` has been revendored to Gardener v1.144.1 and now supports Kubernetes 1.31 to 1.35. Worker pools honor the configured update strategy, including in-place updates.
VPA resources now use `autoscaling.k8s.io/v1`, and containerd is pinned to 1.7.x to avoid a regression present in containerd 2.2.

lotharbach and others added 28 commits March 7, 2025 14:56
Reconciles 173 upstream commits (mostly Renovate dependency bumps) on top of
the Gardener v1.144.1 revendor. Only go.mod/go.sum conflicted; resolved by
keeping this branch's dependency tree (gardener v1.144.1 supersedes upstream's
pinned v1.106.1). Absorbs upstream's renovate.json and CI script updates.

Verified: go mod tidy is a no-op, go build/vet/test ./pkg/... all pass.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Also MCM v0.62.1 and hcloud-go v2.44.0. x/net moves to v0.56.0, clearing 7
advisories.

v1.146 removed the gardener/gardener/hack package and hack/vgopath-setup.sh.
The latter was sourced by update-codegen.sh under errexit, which broke make
generate and therefore the release workflow that builds
example/controller-registration.yaml. vgopath is replaced by the hack/tools
nested module, pinned to v1.146.4 in lockstep with core: hack/tools v1.147.0
requires controller-runtime v0.24.1 and k8s v0.36.2, which MVS would propagate
to the whole staging set. k8s.io/* stay at v0.35.5 and controller-runtime at
v0.23.3 to match gardener v1.146.4 exactly.

WorkerPoolHash merged additionalDataV1/V2 into a single additionalData
parameter. The computed hash is unchanged for a nil-additionalData call, so no
MachineClass is renamed and no worker pool rolls. The worker mock never set
NodeAgentSecretName and so exercised the V1 hash fallback that v1.146 removed;
gardenlet always sets the field, so the fixture now matches production.
Hetzner stops returning Datacenter.ServerTypes after 2026-10-01 and has
deprecated the datacenters API. Availability is now derived from
ServerType.Locations. Also stop discarding the API error, which previously
turned any API failure into a bogus "machine type not available" for every
pool.
CCM v1.33.0 and csi-driver v2.22.0. csi-node-driver-registrar v2.17.0 and
livenessprobe v2.19.0 are pure CVE fixes with no flag or RBAC changes.
csi-attacher, csi-resizer and csi-provisioner stay on the matrix that
csi-driver v2.22.0 pins and tests. Go builder to 1.26.5, matching gardener.
controller-runtime v0.24.x and VPA v1.7.x require k8s v0.36, which would
silently break alignment with gardener v1.146.4, and gomod PRs were set to
automerge. Group the gardener modules so core, pkg/apis and hack/tools move
together.
…e manager

Everything was on node12/node16-era pins from ~2020; Node 20 is removed from
runners on 2026-09-16. All eight actions now declare node24.

setup-go was floating on go-version ">=1.21.0", which silently tracked newest
stable rather than the go directive; it now reads go.mod.

github-actions was missing from enabledManagers, which is why these pins rotted
while gomod stayed current. Enabling it after the bump means no backlog of
per-major PRs.
The removed hack/vgopath-setup.sh ran `go mod download` internally. Without it,
`go list -m -f {{.Dir}}` returns empty on a cold cache, so CODE_GEN_DIR was
empty and update-codegen.sh sourced /kube_codegen.sh. The Makefile also
resolves GARDENER_HACK_DIR and GARDENER_TOOL_DIR the same way at parse time,
before any recipe runs, so the workflow downloads first. The GOPATH export was
only needed by vgopath.
Signed-off-by: Christian Hüning <christianhuening@users.noreply.github.com>
Adopt the extension into the opendefensecloud org. Renames the module
path github.com/23technologies/gardener-extension-provider-hcloud ->
github.com/opendefensecloud/gardener-extension-provider-hcloud across all
imports, go.mod, the Dockerfile (WORKDIR + image.source label), README and
docs. No functional change.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
- Makefile REGISTRY/PROJECT_NAME -> opendefensecloud
- provider + admission chart image repositories -> ghcr.io/opendefensecloud
  (admission reconciled to the CI-published name gardener-extension-admission-hcloud)
- charts/images.yaml machine-controller-manager-provider-hcloud image,
  sourceRepository and renovate depName -> opendefensecloud (tag unchanged)
- CODEOWNERS team -> @opendefensecloud/developers
- regenerate example/controller-registration.yaml

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Result of `make tidy` — refreshes vendored .github issue/PR templates to
match the current gardener dependency (crypto label guidance, internal-info
notices). No functional change.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

No released version runs on Kubernetes ≥ 1.34 seeds — unsupported kubernetes version "v1.35.4"

2 participants